package org.fly.service;

import org.fly.bean.Order;
import org.fly.bean.OrderProduct;
import org.fly.bean.query.OrderQuery;
import org.fly.bean.common.BusinessException;
import org.fly.bean.warpper.OrderWarpper;

import java.util.List;

/**
* Created by autoCode on 2018-04-10 19:13:41.
*/
public interface OrderService {

    List<Order> list(OrderQuery query);

    long count(OrderQuery query);

    List<OrderWarpper> listWarpper(OrderQuery query);

    void updateOrderStatus(String orderId,String status)throws BusinessException;

    Order findById(String id);

    void save(Order bean)  throws BusinessException;

    void delete(String id);

    void createByProduct(OrderProduct orderProduct,String customerId) throws BusinessException;

    void createByCart(List<String> cartIdList,String customerId )throws BusinessException;

}
